﻿using System;
using MySql.Simple.Mapper.Structures;

namespace MySql.Simple.Mapper.Attributes
{
    [AttributeUsage(AttributeTargets.Property)]
    public class IndexAttribute : Attribute
    {
        /// <summary>
        /// Gets or sets the type of the index.
        /// </summary>
        /// <value>The type of the index.</value>
        public IndexType IndexType { get; set; }

        /// <summary>
        /// Gets or sets the length of the index.
        /// </summary>
        /// <value>The length.</value>
        public int Length { get; set; }

        /// <summary>
        /// Gets or sets the name of the index.
        /// </summary>
        /// <value>The name.</value>
        public string Name { get; set; }
    }
}
